package com.ruoyi.shop.modules.domain;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 订单对象 ord_order
 *
 * @author zjc
 * @date 2024-06-26
 */
@TableName("ord_order")
public class Order extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     * 订单id
     */
    private Long id;

    /**
     * 用户id
     */
    @Excel(name = "用户id")
    private Long memberId;

    /**
     * 优惠券id
     */
    @Excel(name = "优惠券id")
    private Long couponId;

    /**
     * 订单编号
     */
    @Excel(name = "订单编号")
    private String orderSn;
    /**
     * 商品id
     **/
    @Excel(name = "商品id")
    private Long productId;


    /**
     * 用户帐号
     */
    @Excel(name = "用户帐号")
    private String memberUsername;

    /**
     * 订单总金额
     */
    @Excel(name = "订单总金额")
    private BigDecimal totalAmount;

    /**
     * 应付金额
     */
    @Excel(name = "应付金额")
    private BigDecimal payAmount;

    /**
     * 运费金额
     */
    @Excel(name = "运费金额")
    private BigDecimal freightAmount;

    /**
     * 促销优化金额
     */
    @Excel(name = "促销优化金额")
    private BigDecimal promotionAmount;

    /**
     * 积分抵扣金额
     */
    @Excel(name = "积分抵扣金额")
    private BigDecimal integrationAmount;

    /**
     * 优惠券抵扣金额
     */
    @Excel(name = "优惠券抵扣金额")
    private BigDecimal couponAmount;

    /**
     * 管理员后台调整订单使用的折扣金额
     */
    @Excel(name = "管理员后台调整订单使用的折扣金额")
    private BigDecimal discountAmount;

    /**
     * 支付方式
     */
    @Excel(name = "支付方式")
    private Long payType;

    /**
     * 订单来源
     */
    @Excel(name = "订单来源")
    private Long sourceType;

    /**
     * 订单状态
     */
    @Excel(name = "订单状态")
    private Long status;

    /**
     * 订单类型
     */
    @Excel(name = "订单类型")
    private Long orderType;

    /**
     * 物流公司
     */
    @Excel(name = "物流公司")
    private String deliveryCompany;

    /**
     * 物流单号
     */
    @Excel(name = "物流单号")
    private String deliverySn;

    /**
     * 自动确认时间
     */
    @Excel(name = "自动确认时间")
    private Long autoConfirmDay;

    /**
     * 可以获得的积分
     */
    @Excel(name = "可以获得的积分")
    private Long integration;

    /**
     * 可以活动的成长值
     */
    @Excel(name = "可以活动的成长值")
    private Long growth;

    /**
     * 活动信息
     */
    @Excel(name = "活动信息")
    private String promotionInfo;

    /**
     * 发票类型
     */
    @Excel(name = "发票类型")
    private Long billType;

    /**
     * 发票头
     */
    @Excel(name = "发票头")
    private String billHeader;

    /**
     * 发票内容
     */
    @Excel(name = "发票内容")
    private String billContent;

    /**
     * 收票人电话
     */
    @Excel(name = "收票人电话")
    private String billReceiverPhone;

    /**
     * 收票人邮箱
     */
    @Excel(name = "收票人邮箱")
    private String billReceiverEmail;

    /**
     * 收货人姓名
     */
    @Excel(name = "收货人姓名")
    private String receiverName;

    /**
     * 收货人电话
     */
    @Excel(name = "收货人电话")
    private String receiverPhone;

    /**
     * 收货人邮编
     */
    @Excel(name = "收货人邮编")
    private String receiverPostCode;

    /**
     * 省份/直辖市
     */
    @Excel(name = "省份/直辖市")
    private String receiverProvince;

    /**
     * 城市
     */
    @Excel(name = "城市")
    private String receiverCity;

    /**
     * 区
     */
    @Excel(name = "区")
    private String receiverRegion;

    /**
     * 详细地址
     */
    @Excel(name = "详细地址")
    private String receiverDetailAddress;

    /**
     * 订单备注
     */
    @Excel(name = "订单备注")
    private String note;

    /**
     * 确认收货状态：0-&gt;未确认；1-&gt;已确认
     */
    @Excel(name = "确认收货状态：0-&gt;未确认；1-&gt;已确认")
    private Long confirmStatus;

    /**
     * 删除状态
     */
    @Excel(name = "删除状态")
    private Long deleteStatus;

    /**
     * 下单时使用的积分
     */
    @Excel(name = "下单时使用的积分")
    private Long useIntegration;

    /**
     * 支付时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "支付时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date paymentTime;

    /**
     * 发货时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "发货时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date deliveryTime;

    /**
     * 确认收货时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "确认收货时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date receiveTime;

    /**
     * 评价时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "评价时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date commentTime;

    /**
     * 修改时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date modifyTime;

    public Long getProductId() {
        return productId;
    }

    public void setProductId(Long productId) {
        this.productId = productId;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

    public void setMemberId(Long memberId) {
        this.memberId = memberId;
    }

    public Long getMemberId() {
        return memberId;
    }

    public void setCouponId(Long couponId) {
        this.couponId = couponId;
    }

    public Long getCouponId() {
        return couponId;
    }

    public void setOrderSn(String orderSn) {
        this.orderSn = orderSn;
    }

    public String getOrderSn() {
        return orderSn;
    }

    public void setMemberUsername(String memberUsername) {
        this.memberUsername = memberUsername;
    }

    public String getMemberUsername() {
        return memberUsername;
    }

    public void setTotalAmount(BigDecimal totalAmount) {
        this.totalAmount = totalAmount;
    }

    public BigDecimal getTotalAmount() {
        return totalAmount;
    }

    public void setPayAmount(BigDecimal payAmount) {
        this.payAmount = payAmount;
    }

    public BigDecimal getPayAmount() {
        return payAmount;
    }

    public void setFreightAmount(BigDecimal freightAmount) {
        this.freightAmount = freightAmount;
    }

    public BigDecimal getFreightAmount() {
        return freightAmount;
    }

    public void setPromotionAmount(BigDecimal promotionAmount) {
        this.promotionAmount = promotionAmount;
    }

    public BigDecimal getPromotionAmount() {
        return promotionAmount;
    }

    public void setIntegrationAmount(BigDecimal integrationAmount) {
        this.integrationAmount = integrationAmount;
    }

    public BigDecimal getIntegrationAmount() {
        return integrationAmount;
    }

    public void setCouponAmount(BigDecimal couponAmount) {
        this.couponAmount = couponAmount;
    }

    public BigDecimal getCouponAmount() {
        return couponAmount;
    }

    public void setDiscountAmount(BigDecimal discountAmount) {
        this.discountAmount = discountAmount;
    }

    public BigDecimal getDiscountAmount() {
        return discountAmount;
    }

    public void setPayType(Long payType) {
        this.payType = payType;
    }

    public Long getPayType() {
        return payType;
    }

    public void setSourceType(Long sourceType) {
        this.sourceType = sourceType;
    }

    public Long getSourceType() {
        return sourceType;
    }

    public void setStatus(Long status) {
        this.status = status;
    }

    public Long getStatus() {
        return status;
    }

    public void setOrderType(Long orderType) {
        this.orderType = orderType;
    }

    public Long getOrderType() {
        return orderType;
    }

    public void setDeliveryCompany(String deliveryCompany) {
        this.deliveryCompany = deliveryCompany;
    }

    public String getDeliveryCompany() {
        return deliveryCompany;
    }

    public void setDeliverySn(String deliverySn) {
        this.deliverySn = deliverySn;
    }

    public String getDeliverySn() {
        return deliverySn;
    }

    public void setAutoConfirmDay(Long autoConfirmDay) {
        this.autoConfirmDay = autoConfirmDay;
    }

    public Long getAutoConfirmDay() {
        return autoConfirmDay;
    }

    public void setIntegration(Long integration) {
        this.integration = integration;
    }

    public Long getIntegration() {
        return integration;
    }

    public void setGrowth(Long growth) {
        this.growth = growth;
    }

    public Long getGrowth() {
        return growth;
    }

    public void setPromotionInfo(String promotionInfo) {
        this.promotionInfo = promotionInfo;
    }

    public String getPromotionInfo() {
        return promotionInfo;
    }

    public void setBillType(Long billType) {
        this.billType = billType;
    }

    public Long getBillType() {
        return billType;
    }

    public void setBillHeader(String billHeader) {
        this.billHeader = billHeader;
    }

    public String getBillHeader() {
        return billHeader;
    }

    public void setBillContent(String billContent) {
        this.billContent = billContent;
    }

    public String getBillContent() {
        return billContent;
    }

    public void setBillReceiverPhone(String billReceiverPhone) {
        this.billReceiverPhone = billReceiverPhone;
    }

    public String getBillReceiverPhone() {
        return billReceiverPhone;
    }

    public void setBillReceiverEmail(String billReceiverEmail) {
        this.billReceiverEmail = billReceiverEmail;
    }

    public String getBillReceiverEmail() {
        return billReceiverEmail;
    }

    public void setReceiverName(String receiverName) {
        this.receiverName = receiverName;
    }

    public String getReceiverName() {
        return receiverName;
    }

    public void setReceiverPhone(String receiverPhone) {
        this.receiverPhone = receiverPhone;
    }

    public String getReceiverPhone() {
        return receiverPhone;
    }

    public void setReceiverPostCode(String receiverPostCode) {
        this.receiverPostCode = receiverPostCode;
    }

    public String getReceiverPostCode() {
        return receiverPostCode;
    }

    public void setReceiverProvince(String receiverProvince) {
        this.receiverProvince = receiverProvince;
    }

    public String getReceiverProvince() {
        return receiverProvince;
    }

    public void setReceiverCity(String receiverCity) {
        this.receiverCity = receiverCity;
    }

    public String getReceiverCity() {
        return receiverCity;
    }

    public void setReceiverRegion(String receiverRegion) {
        this.receiverRegion = receiverRegion;
    }

    public String getReceiverRegion() {
        return receiverRegion;
    }

    public void setReceiverDetailAddress(String receiverDetailAddress) {
        this.receiverDetailAddress = receiverDetailAddress;
    }

    public String getReceiverDetailAddress() {
        return receiverDetailAddress;
    }

    public void setNote(String note) {
        this.note = note;
    }

    public String getNote() {
        return note;
    }

    public void setConfirmStatus(Long confirmStatus) {
        this.confirmStatus = confirmStatus;
    }

    public Long getConfirmStatus() {
        return confirmStatus;
    }

    public void setDeleteStatus(Long deleteStatus) {
        this.deleteStatus = deleteStatus;
    }

    public Long getDeleteStatus() {
        return deleteStatus;
    }

    public void setUseIntegration(Long useIntegration) {
        this.useIntegration = useIntegration;
    }

    public Long getUseIntegration() {
        return useIntegration;
    }

    public void setPaymentTime(Date paymentTime) {
        this.paymentTime = paymentTime;
    }

    public Date getPaymentTime() {
        return paymentTime;
    }

    public void setDeliveryTime(Date deliveryTime) {
        this.deliveryTime = deliveryTime;
    }

    public Date getDeliveryTime() {
        return deliveryTime;
    }

    public void setReceiveTime(Date receiveTime) {
        this.receiveTime = receiveTime;
    }

    public Date getReceiveTime() {
        return receiveTime;
    }

    public void setCommentTime(Date commentTime) {
        this.commentTime = commentTime;
    }

    public Date getCommentTime() {
        return commentTime;
    }

    public void setModifyTime(Date modifyTime) {
        this.modifyTime = modifyTime;
    }

    public Date getModifyTime() {
        return modifyTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("memberId", getMemberId())
                .append("couponId", getCouponId())
                .append("productId", getProductId())
                .append("orderSn", getOrderSn())
                .append("createTime", getCreateTime())
                .append("memberUsername", getMemberUsername())
                .append("totalAmount", getTotalAmount())
                .append("payAmount", getPayAmount())
                .append("freightAmount", getFreightAmount())
                .append("promotionAmount", getPromotionAmount())
                .append("integrationAmount", getIntegrationAmount())
                .append("couponAmount", getCouponAmount())
                .append("discountAmount", getDiscountAmount())
                .append("payType", getPayType())
                .append("sourceType", getSourceType())
                .append("status", getStatus())
                .append("orderType", getOrderType())
                .append("deliveryCompany", getDeliveryCompany())
                .append("deliverySn", getDeliverySn())
                .append("autoConfirmDay", getAutoConfirmDay())
                .append("integration", getIntegration())
                .append("growth", getGrowth())
                .append("promotionInfo", getPromotionInfo())
                .append("billType", getBillType())
                .append("billHeader", getBillHeader())
                .append("billContent", getBillContent())
                .append("billReceiverPhone", getBillReceiverPhone())
                .append("billReceiverEmail", getBillReceiverEmail())
                .append("receiverName", getReceiverName())
                .append("receiverPhone", getReceiverPhone())
                .append("receiverPostCode", getReceiverPostCode())
                .append("receiverProvince", getReceiverProvince())
                .append("receiverCity", getReceiverCity())
                .append("receiverRegion", getReceiverRegion())
                .append("receiverDetailAddress", getReceiverDetailAddress())
                .append("note", getNote())
                .append("confirmStatus", getConfirmStatus())
                .append("deleteStatus", getDeleteStatus())
                .append("useIntegration", getUseIntegration())
                .append("paymentTime", getPaymentTime())
                .append("deliveryTime", getDeliveryTime())
                .append("receiveTime", getReceiveTime())
                .append("commentTime", getCommentTime())
                .append("modifyTime", getModifyTime())
                .toString();
    }
}
